cmake_minimum_required(VERSION 3.15)

# 目标平台系统名称，裸机嵌入式一般就写 Generic
set(CMAKE_SYSTEM_NAME Generic)
# 禁用编译器检查
set(CMAKE_C_COMPILER_WORKS TRUE)
set(CMAKE_CXX_COMPILER_WORKS TRUE)

project(ZynqTimer)

# 设置编译选项,-c必须要加,否则点击编译后一堆错误
set(CMAKE_C_FLAGS "-Wall -O0 -g3 -c -fmessage-length=0 -mcpu=cortex-a9 -mfpu=vfpv3 -mfloat-abi=hard")
set(CMAKE_CXX_FLAGS "-Wall -O0 -g3 -c -fmessage-length=0 -mcpu=cortex-a9 -mfpu=vfpv3 -mfloat-abi=hard")

# 设置通用的搜索文件
set(SourceFileTypes "./*.h" "./*.hpp" "./*.cpp" "./*.cxx" "./*.c" "./*.cc")

# 设置BSP的工作环境
include_directories("${CMAKE_SOURCE_DIR}/../system_wrapper/export/system_wrapper/sw/system_wrapper/standalone_ps7_cortexa9_0/bspinclude/include")

add_subdirectory(Main)
# add_subdirectory(third)


#add_compile_definitions(__cplusplus=201703L)

